package main

import "fmt"

type TwoInts struct {
	a, b int
}

func main() {
	data := &TwoInts{3, 5}
	fmt.Println("data is: ", data)
	fmt.Println("sum of data is: ", data.AddItem())
	fmt.Println("data sum add 9: ", data.AddItemToParam(9))
}

func (t *TwoInts) AddItem() int {
	return t.a + t.b
}

func (t *TwoInts) AddItemToParam(p int) int {
	return t.AddItem() + p
}
